/**
 * Created with IntelliJ IDEA.
 *
 * @Auther: YaoSC
 * @Date: 2019/09/17/21:23
 * @Description:
 */

package com.orhon.smartcampus.modules.systemctl.entity;

import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;

import javax.persistence.*;

/**
 *@Author: YSC
 *@Description:   操作权限菜单关系
 *@Date: Created in21:23  2019/9/17
 */

@Setter
@Getter
@EqualsAndHashCode
@Entity
@Table(name = "systemctl_operation_menu", schema = "smartcloud", catalog = "")
public class SystemctlOperationMenu {

    @Id
    Integer id;
    @ManyToOne
    @JoinColumn(name = "menu_id", referencedColumnName = "id")
    @NotFound(action= NotFoundAction.IGNORE)
    private  Menus menus; //菜单
    @ManyToOne
    @JoinColumn(name = "operation_id", referencedColumnName = "id")
    @NotFound(action= NotFoundAction.IGNORE)
    private Operations operation;   //权限



}